 export const getUserProfile = ()=>{
 	return new Promise(function(resolve,reject){
 		uni.getUserProfile({
 			desc:'获取用户个人信息',
 			success:(res)=>{
 				resolve(res)
 			},
 			fail:(err)=>{
 				uni.showToast({
 				title:"用户拒绝了获取个人信息"
 			});
 			reject(error);
 			}
 		})
 	})
 }
export const login =()=>{
	return new Promise(function(resolve,reject){
		uni.login({
			success(res) {
				resolve(res);
			},
			fail(error) {
				reject(error);
			}
		})
	})
}
// 添加一个支付的函数
export const requestPayment = (params)=>{
	return new Promise(function(resolve,reject){
		uni.requestPayment({
			...params,
			success: (res) => {
				resolve(res);
			},
			fail: (error) => {
				reject(error);
			}
		})
	})
}